package com.gzhryc.shared_device.oem.code.place.dao.db;

import com.gzhryc.jdbc.annotaion.*;
import com.gzhryc.shared_device.oem.code.business.EBusinessType;

import java.util.Date;

@Table(name="place_business_config")
public class PlaceBusinessConfig {

    @PrimaryKey
    @Column(name = "place_id", notNull = true, note = "网点ID")
    protected Long placeId;

    @PrimaryKey
    @Column(name = "business_type", notNull = true, note = "业务类型")
    protected String businessType;

    @Column(name="fee_template_id",note = "收费模版ID")
    protected Long feeTemplateId;

    @Column(name="fee_template_title",length = 64,note = "收费模版标题")
    protected String feeTemplateTitle;

    @Column(name="cost_content",type = "TEXT",note = "配置内容")
    protected String costContent;

    @Column(name="device_count",notNull = true,defVal = "0",note = "设备数量")
    protected Integer deviceCount;

    @Column(name = "update_date", autoUpdateTime = true, note = "最后修改时间")
    protected Date updateDate;

    @Column(name = "create_date")
    protected Date createDate;

    public Long getPlaceId() {
        return placeId;
    }

    public void setPlaceId(Long placeId) {
        this.placeId = placeId;
    }

    public String getBusinessType() {
        return businessType;
    }

    public void setBusinessType(String businessType) {
        this.businessType = businessType;
    }

    public Long getFeeTemplateId() {
        return feeTemplateId;
    }

    public void setFeeTemplateId(Long feeTemplateId) {
        this.feeTemplateId = feeTemplateId;
    }

    public String getFeeTemplateTitle() {
        return feeTemplateTitle;
    }

    public void setFeeTemplateTitle(String feeTemplateTitle) {
        this.feeTemplateTitle = feeTemplateTitle;
    }

    public String getCostContent() {
        return costContent;
    }

    public void setCostContent(String costContent) {
        this.costContent = costContent;
    }

    public Integer getDeviceCount() {
        return deviceCount;
    }

    public void setDeviceCount(Integer deviceCount) {
        this.deviceCount = deviceCount;
    }

    public Date getUpdateDate() {
        return updateDate;
    }

    public void setUpdateDate(Date updateDate) {
        this.updateDate = updateDate;
    }

    public Date getCreateDate() {
        return createDate;
    }

    public void setCreateDate(Date createDate) {
        this.createDate = createDate;
    }

    public String getBusinessTypeName() {
        return EBusinessType.note(this.businessType);
    }
}
